Skip to content

Repair lesson correctness and add private account progress - #19

Draft
hananather wants to merge 60 commits into
mainfrom
codex/platform-foundation
Draft

hananather wants to merge 60 commits into
mainfrom
codex/platform-foundation

Conversation

@hananather

@hananather hananather commented Oct 3, 2026 •

Copy link
Copy Markdown
Owner

Probability Lab had incorrect numerical results, fragile quiz/progress state, and account quiz results that saved locally but failed cloud validation. This change repairs those paths, preserves public lessons and guest access, and adds optional account sign-in with private, acknowledged progress.

  • Pin grades to complete question banks; retain answers, flags, drafts, pause state and position; support partial finish, review, retake and keyboard navigation. Label recorded duration as time since start, including pauses and time away, while preserving the original recorded value.
  • Unify progress through owner-scoped IndexedDB with loss-preserving migration, atomic grading, reset/import guards, readback, subscriptions, backups and retry. Keep study completion separate from quiz achievement. Add an explicit Sample study record and device-private learning-mode resume; calculations and practice answers remain visit-only.
  • Add optional Supabase email/PKCE sign-in, server-verified account binding, same-origin checks, owner RLS and revision compare-and-swap SQL. Account drafts and reading positions stay on their device. Guest transfer is explicit. Defer guest totals and backup/recovery controls while the destination is being checked; restore sync-action keyboard focus only while its initiating intent is current.
  • Repair full-bank account quiz projection. Existing rejected grades can be explicitly retried with their original operation ID and reset lineage; exact original archives remain exportable. Account switches, expiry, stale resets and oversized records retain their guards.
  • Correct distribution, integration, coverage, paired-test, quartile and F-test edge cases; repair answer keys and worked correlation arithmetic from the actual 20 paired observations. Clarify sample-correlation notation, sampling assumptions and perfect-correlation limits.
  • Normalize empirical density by all retained samples and actual bin width. Restore sampling after distribution changes and responsive chart sizing. Improve ordinary/reduced motion, keep controls usable during transitions, and repair phone navigation cards.
  • Correct confidence critical values and sample-size half-width wording. Retain the computed normal quantile until the final integer ceiling: the 98% plan with σ=1.7 and E=0.1 now requires 1,565 observations instead of 1,564. Show rounded worked values with approximation signs and render safe scientific notation for valid extremes. Validate calculator inputs, provide keyboard formula/preset controls, clear stale practice feedback, require integer sample-size answers, and clarify standard error and interval width. Solve budget plans with exact decimal integer constraints; distinguish required completed measurements from enrollment planned for expected losses. Retain independent math and responsive/motion controls.
  • Serialize MathJax rendering with bounded retries and cleanup; use actual Next bundled React and TeX/CHTML fixtures. Add JSX lint, production route checks and CI, and patch framework/plotting dependencies.
  • Defer the browser authentication SDK until server-verified account activation or explicit email submission. Preserve cross-tab hints, PKCE cookies and account generation/expiry guards.
  • Add contributor and module guides plus a source-provenance ledger. Preserve author credits and explicitly retain unresolved source/asset/license gates. Document optional account setup and accurate privacy/storage behavior. Align the math-rendering guide with the current shared hook, wrapper and safety boundary.

Validation: the tracked-clean configured production head 8dc2609 passed 1,210 tests in 100 files, with one explicit local-provider fixture skipped, ESLint with zero errors and 109 warnings, the production build, and 110 page HTTP checks. The contribution guides separately verified 45 local links/anchors and five external source URLs. The revised math-rendering guide verified six local links and parsed all three JSX examples against the installed transformer. Hosted quality checks at this exact head passed.

Independent account controls passed 205 targeted tests, 22 full-bank/UI probes covering all 21 chapter/version selections (including fallbacks), and 19 naturally generated pre-repair recovery controls. Other scoped checks cover numerical calculations, actual MathJax rendering, responsive charts, motion/lifecycle behavior and teaching corrections.

On October 3, actual local PostgreSQL/Auth/REST separately passed 30 transactional SQL controls and an ordinary-token RLS/CAS integration case. Native email delivery and same-browser PKCE sign-in succeeded. At 80bf216, the original affected Chrome profile explicitly recovered its failed 1/18 Chapter 4 grade; the real database accepted the original operation receipt. Reload and UI backup export retained the exact original archives. A separate browser fetched that result, kept its unfinished Chapter 3 draft private, finished it through the real UI, and synchronized the new grade to the other profile after a sync check. Local sign-out preserved guest history and the other profile's account session. Account controls fit settled 320/390/1440 layouts. At 7bdb749, fresh native email delivery and same-browser PKCE return again synchronized the retained four quiz chapters; read-only database metadata confirmed unchanged grades and the original applied receipt. These are local functionality checks, not production-provider certification, real-time push guarantees or measured learning outcomes.

Two independent SDK reviews and root controls passed 228 targeted cases plus one explicit provider-fixture skip. Same-configuration production asset comparison against 8a850af removed 68,067 gzip bytes from initial referenced scripts on home/progress/sample-size (22.38%/22.29%/16.26%). A fresh browser origin exercised guest hydration, lesson controls and sign-in navigation without requesting the identified SDK chunks; explicit email submission requested both chunks with HTTP200 and delivered its local email. Compression totals describe individually compressed prerendered script assets, not measured latency, parsing or frame rate.

At 8dc2609, independent Sample numerical review passed 100 retained/new public controls and eight fresh component/MathJax controls; the author’s nine-file scoped gate passed 149 tests. Independent presentation review passed 23 fresh controls and 120 retained controls. Native calculator checks confirmed the four boundary counts, large finite/extreme valid inputs, rendered approximation/ceiling steps, saved values and 320/390 document bounds. Ordinary/reduced motion controls worked; no frame-rate claim is inferred. Visiting/exploring kept study at 1/66; explicitly marking the lesson raised it to 2/66 and synchronized to the separate browser, whose selected learning mode stayed private. Both browsers retained four quiz chapters and the original applied recovery receipt; all seven original quiz attempts and grades were unchanged. Keyboard sync returned focus in both browsers. The retained latest quiz displayed its original 1/18 grade and wall duration of 1d 8h 12m 21s with an honest label. Fresh navigation/reload deferred progress details and backup controls during account verification.

Remaining work includes full sample-size lesson quality, selected-state/chart-text/mobile formula improvements, additional native account-switch/offline/reset and cross-version history scenarios, focused learning/spaced review, rights/licensing and the page/module/question quality gate. Unreviewed material remains unscored. The PR remains a draft. Work is paused at the maintainer’s request; the roadmap checkpoint records where to resume.

Fixes #5. Related: #8, #9, #10, #11, #12, #13, #14, #15, #16, #17, #18.

@vercel

vercel Bot commented Oct 3, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
probability Ready Ready Preview Oct 5, 2026 10:53am UTC
probability-uo Ready Ready Preview Oct 5, 2026 10:53am UTC
probability-uottawa Ready Ready Preview Oct 5, 2026 10:53am UTC

@hananather hananather changed the title Establish learning platform regression gates and repair core interactions Repair probability calculations, learning controls, and local progress foundations Oct 3, 2026
@hananather hananather changed the title Repair probability calculations, learning controls, and local progress foundations Repair lesson correctness and learner progress foundations Oct 4, 2026

This branch was successfully deployed

3 active deployments
Preview – probability-uo — 8dc26098 Deployed Oct 5, 2026 by vercel[bot]
Preview – probability-uottawa — 8dc26098 Deployed Oct 5, 2026 by vercel[bot]
Preview – probability — 8dc26098 Deployed Oct 5, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Chapter Buttons on home page:

1 participant